package vn.com.fsoft.model.entities;

import javax.persistence.*;

@Entity
@Table(name="PROGRAMME")
public class Programme implements java.io.Serializable{
	
	/**
	 * 
	 */
	private static final long serialVersionUID = 6744421875131993061L;
	private int programmeId;
	private Contact contactProgramme;
	private String programmeName;
	private String description;
	
	public Programme(){
		super();
	}
	
	public Programme(int programmeId, Contact contactProgramme,
			String programmeName, String description) {
		super();
		this.programmeId = programmeId;
		this.contactProgramme = contactProgramme;
		this.programmeName = programmeName;
		this.description = description;
	}
	@Id
	@GeneratedValue(strategy=GenerationType.IDENTITY)
	@Column(name="PROGRAMME_ID", unique=true,nullable=false)
	public int getProgrammeId() {
		return programmeId;
	}
	public void setProgrammeId(int programmeId) {
		this.programmeId = programmeId;
	}
	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "CONTACT_ID", nullable = false)
	public Contact getContactProgramme() {
		return contactProgramme;
	}
	public void setContactProgramme(Contact contactProgramme) {
		this.contactProgramme = contactProgramme;
	}
	@Column(name="PROGRAMME_NAME",length=50)
	public String getProgrammeName() {
		return programmeName;
	}
	public void setProgrammeName(String programmeName) {
		this.programmeName = programmeName;
	}
	@Column(name="DESCRIPTION",length=100)
	public String getDescription() {
		return description;
	}
	public void setDescription(String description) {
		this.description = description;
	}
	
	
	
}
